import { createApp } from 'vue'
// 引入Element-plus UI组件库
import ElementPlus from 'element-plus'
// 引入Element-plus UI组件库 所需的样式文件
import 'element-plus/dist/index.css'
//引入路由
import router from './router'

import App from './App.vue'
import { createPinia } from 'pinia'
//导入持久化插件
import {createPersistedState} from'pinia-persistedstate-plugin'

const app = createApp(App);
const pinia = createPinia()

//实例化插件
const persist = createPersistedState()
//并将插件注册到pinia
pinia.use(persist)

// 注册Element-plus UI组件库
app.use(ElementPlus);

//注册路由
app.use(router);

//注册pinia
app.use(pinia)


app.mount('#app');



